from flask import Flask

app = Flask(__name__)

#路由地址
@app.route('/')
def index():
    return 'Hello'

@app.route('/json/')
def return_json():
    return {'name':'zhangsan','age':18}

@app.route('/tuple/')
def return_tuple():
    return 'tuple',201,{'name':'zhangsan'}

if __name__ == '__main__':
    #启动web应用服务
    app.run(debug=True)